from pygame.locals import *
from pygameExt import *
import os

class keyListener:
    def __init__(self, characters, key, function):
        self.key = key
        self.function = function
        self.characters = characters

class screeninherit:
    def reportKey(self, key):
        for curkey in self.keylisteners:
           for character in curkey.characters:
               if (key == character.controls.getAction(curkey.key)):
                   curkey.function(character)